var fs=require('fs')

var buff=new Buffer.alloc(1024)

fs.open('file/test.txt','r+',function (err,fd) {

     fs.read(fd,buff,0,buff.length,0,function (err,bytes) {

         console.log(bytes+" 字节被读取！")

         if(bytes>0){
             console.log(buff.slice(0,bytes).toString());
         }
     })
})
